import request from '../utils/request'

// 获取面经列表
export const getInterviewList = (params) => {
  return request({
    url: '/admin/interview/query',
    params,
  })
}

//添加面经
export const addInterview = (data) => {
  return request({
    method: 'POST',
    url: '/admin/interview/create',
    data,
  })
}

//修改面经
//get post put delete
// get delete参数写在params中
//post put参数写在data中
export const editInterview = (data) => {
  return request({
    method: 'PUT',
    url: '/admin/interview/update',
    data,
  })
}

//删除面经
export const deleteInterview = (id) => {
  return request({
    method: 'DELETE',
    url: '/admin/interview/remove',
    data: {
      id,
    },
  })
}
